<div ng-controller="AccountCtrl as vm">
<section class="content-header">
    <!-- Content Header (Page header) -->
    Admin Account Management
    <ol class="breadcrumb">
        <li><a ><i class="fa fa-dashboard"></i> Admin Account Management</a></li>
    </ol>
</section>
<section class="content">
	<div class="row">
		<div class="col-md-12">
			<div class="box box-primary">
                <div class="box-header with-border">
                    <h3 class="box-title">Account List</h3>
                    <div class="pull-right">
                                    <a class="btn btn-primary" ng-click="vm.createAdminUser()">Add</a>
                    </div>
                </div>
                <div class="box-body table-responsive no-padding">
                            <table ng-table="vm.tableParams" class="table table-hover table-bordered table-condensed" show-filter="true">
                            	<tr ng-repeat="ret in $data">
                                    <td title="'User Name'" filter="{ code: 'text'}" sortable="'code'">
                                    {{ret.code}}</td>
						        <td title="'Role'" filter="{ subrole: 'text'}" sortable="'subrole'">
						            {{ret.subrole}}</td>
						        <td title="'Sub-Region'" filter="{ region: 'text'}" sortable="'region'">
                                    <span ng-if="ret.subrole!='Super Admin'">{{ret.region}}</td>
                                
                                <td title="'Actions'">
                                    <a class="btn btn-xs btn-primary" ng-click="vm.editAdminUser(ret)">Edit</a>
                                    <a class="btn btn-xs btn-danger" ng-click="vm.deleteUser(ret.id)">Delete</a>
                                </td>
						    </tr>
                       
                            </table>
                </div>
                <!-- /.box-body -->
            </div>
            <!-- /.box -->
		</div>
		
	</div>

</section>
</div>